<template>
    <el-button type="primary" style="margin-left: 16px" @click="loginDrawer = true">
        登录
    </el-button>

    <el-drawer
            v-model="loginDrawer"
            title="I am the title"
            :with-header="false"
            direction="ltr"
            style="text-align: center">
        <h1 style="font-size: 40px;color: #2c3e50">登录</h1>
        <el-button style="margin-left: 16px" @click="regDrawerByLogin = true">
            没有账号？立即注册
        </el-button>

        <el-drawer
                v-model="regDrawerByLogin"
                title="I am the title"
                :with-header="false"
                direction="ltr">
            <h1 style="font-size: 40px;color: #2c3e50">注册</h1>
            <reg/>
        </el-drawer>

        <login/>
    </el-drawer>
</template>

<script setup>
import Login from "@/components/Login.vue";
import Reg from "@/components/Reg.vue";
import {ref} from "vue";

const loginDrawer = ref(false)


const regDrawerByLogin = ref(false)

</script>

<style scoped>

</style>